import service from "./index.js";

// 获取页数
export function pageCount(data) {
    return service({
        url: '/admin/class/page/count',
        method: 'get',
        params: data
    })
}
// 获取列表数据
export function page(data, page) {
    return service({
        url: '/admin/class/page/' + page,
        method: 'get',
        params: data
    })
}
// 获取专业名
export function majorNames() {
    return service({
        url: '/admin/major/names',
        method: 'get',
    })
}
// 添加班级
export function classAdd(data) {
    return service({
        url: '/admin/class',
        method: 'post',
        data: data,
    })
}
// 删除班级
export function mixinDelete(id) {
    return service({
        url: '/admin/class/' + id,
        method: 'delete',
    })
}
// 获取详情
export function getClass(id) {
    return service({
        url: '/admin/class/' + id,
        method: 'get'
    })
}
// 修改班级
export function classEdit(data) {
    return service({
        url: '/admin/class',
        method: 'put',
        data: data
    })
}